package com.piece.module.generator.config;

import org.jsonschema2pojo.*;
import org.jsonschema2pojo.rules.RuleFactory;
import java.io.File;
import java.io.FileFilter;
import java.net.URL;
import java.nio.charset.StandardCharsets;
import java.util.Collections;
import java.util.Iterator;
import java.util.Map;

public class JsonSchemaGeneratorConfig implements GenerationConfig {

    public JsonSchemaGeneratorConfig() {
    }

    private SourceType sourceType = SourceType.JSONSCHEMA;

    public void setSourceType(SourceType sourceType) {
        this.sourceType = sourceType;
    }

    @Override
    public boolean isGenerateBuilders() {
        return false;
    }

    @Override
    public boolean isIncludeTypeInfo() {
        return false;
    }

    @Override
    public boolean isIncludeConstructorPropertiesAnnotation() {
        return false;
    }

    @Override
    public boolean isUsePrimitives() {
        return true;
    }

    @Override
    public Iterator<URL> getSource() {
        throw new UnsupportedOperationException("No default source available");
    }

    @Override
    public File getTargetDirectory() {
        return new File(".");
    }

    @Override
    public String getTargetPackage() {
        return "";
    }

    @Override
    public char[] getPropertyWordDelimiters() {
        return new char[] { '-', ' ', '_' };
    }

    @Override
    public boolean isUseLongIntegers() {
        return false;
    }

    @Override
    public boolean isUseBigIntegers() {
        return false;
    }

    @Override
    public boolean isUseDoubleNumbers() {
        return true;
    }

    @Override
    public boolean isUseBigDecimals() {
        return false;
    }

    @Override
    public boolean isIncludeHashcodeAndEquals() {
        return false;
    }

    @Override
    public boolean isIncludeToString() {
        return false;
    }

    @Override
    public String[] getToStringExcludes() {
        return new String[0];
    }

    @Override
    public AnnotationStyle getAnnotationStyle() {
        return AnnotationStyle.NONE;
    }

    @Override
    public boolean isUseTitleAsClassname() {
        return true;
    }

    @Override
    public InclusionLevel getInclusionLevel() {
        return InclusionLevel.NON_NULL;
    }

    @Override
    public Class<? extends Annotator> getCustomAnnotator() {
        return NoopAnnotator.class;
    }

    @Override
    public Class<? extends RuleFactory> getCustomRuleFactory() {
        return RuleFactory.class;
    }

    @Override
    public boolean isIncludeJsr303Annotations() {
        return false;
    }

    @Override
    public boolean isIncludeJsr305Annotations() {
        return false;
    }

    @Override
    public boolean isUseOptionalForGetters() {
        return false;
    }

    @Override
    public SourceType getSourceType() {
        return this.sourceType;
    }

    @Override
    public boolean isRemoveOldOutput() {
        return false;
    }

    @Override
    public String getOutputEncoding() {
        return StandardCharsets.UTF_8.toString();
    }

    @Override
    public boolean isUseJodaDates() {
        return false;
    }

    @Override
    public boolean isUseJodaLocalDates() {
        return false;
    }

    @Override
    public boolean isUseJodaLocalTimes() {
        return false;
    }

    @Override
    public boolean isParcelable() {
        return false;
    }

    @Override
    public boolean isSerializable() {
        return true;
    }

    @Override
    public FileFilter getFileFilter() {
        return new AllFileFilter();
    }

    @Override
    public boolean isInitializeCollections() {
        return false;
    }

    @Override
    public String getClassNamePrefix() {
        return "";
    }

    @Override
    public String getClassNameSuffix() {
        return "";
    }

    @Override
    public String[] getFileExtensions() {
        return new String[0];
    }

    @Override
    public boolean isIncludeConstructors() {
        return false;
    }

    @Override
    public boolean isConstructorsRequiredPropertiesOnly() {
        return false;
    }

    @Override
    public boolean isIncludeRequiredPropertiesConstructor() {
        return false;
    }

    @Override
    public boolean isIncludeAllPropertiesConstructor() {
        return false;
    }

    @Override
    public boolean isIncludeCopyConstructor() {
        return false;
    }

    @Override
    public boolean isIncludeAdditionalProperties() {
        return false;
    }

    @Override
    public boolean isIncludeGetters() {
        return false;
    }

    @Override
    public boolean isIncludeSetters() {
        return false;
    }

    @Override
    public String getTargetVersion() {
        return "";
    }

    @Override
    public boolean isIncludeDynamicAccessors() {
        return false;
    }

    @Override
    public boolean isIncludeDynamicGetters() {
        return false;
    }

    @Override
    public boolean isIncludeDynamicSetters() {
        return false;
    }

    @Override
    public boolean isIncludeDynamicBuilders() {
        return false;
    }

    @Override
    public String getDateTimeType() {
        return null;
    }

    @Override
    public String getDateType() {
        return null;
    }

    @Override
    public String getTimeType() {
        return null;
    }

    @Override
    public boolean isFormatDates() {
        return false;
    }

    @Override
    public boolean isFormatTimes() {
        return false;
    }

    @Override
    public boolean isFormatDateTimes() {
        return false;
    }

    @Override
    public String getCustomDatePattern() {
        return null;
    }

    @Override
    public String getCustomTimePattern() {
        return null;
    }

    @Override
    public String getCustomDateTimePattern() {
        return null;
    }

    @Override
    public String getRefFragmentPathDelimiters() {
        return "#/.";
    }

    @Override
    public SourceSortOrder getSourceSortOrder() {
        return null;
    }

    @Override
    public Map<String, String> getFormatTypeMapping() {
        return Collections.emptyMap();
    }

    @Override
    public boolean isIncludeGeneratedAnnotation() {
        return false;
    }

    @Override
    public boolean isUseJakartaValidation() {
        return false;
    }

    @Override
    public boolean isUseInnerClassBuilders() {
        return true;
    }
}
